import request from '@/utils/request'

// 注册接口
export const sysUserRegisterService = ({account, password}) => {
	return request.post('/common/register', {
		password,             // 密码
		account,             // 账号
		nickName: account,   // 名称默认和用户名一致
		status: '1'           // 状态默认是启用
	})
}

// 登录接口
export const sysUserLoginService = ({account, password}) => {
	return request.post('/user/login', {
		account,              // 账号
		password               // 密码
	})
}
// 退出登录
export const sysUserLogoutService = () => request.post('/user/logout')
// 获取用户基本信息
export const sysUserInfoService = () => request.get('/user/info')
// 修改用户信息
export const sysUserEditService = data => request.put('/user/edit', data)